package cn.jiguang.demo.test;

import android.content.Intent;
import android.os.Bundle;
import android.view.LayoutInflater;
import android.view.View;
import android.view.ViewGroup;

import androidx.annotation.NonNull;
import androidx.fragment.app.Fragment;

import cn.jiguang.demo.R;

public class MainTestFragment extends Fragment {

    @Override
    public View onCreateView(
            LayoutInflater inflater, ViewGroup container,
            Bundle savedInstanceState
    ) {
        // Inflate the layout for this fragment
        return inflater.inflate(R.layout.d_fragment_test, container, false);
    }

    public void onViewCreated(@NonNull View view, Bundle savedInstanceState) {
        super.onViewCreated(view, savedInstanceState);

        view.findViewById(R.id.btn_adv).setOnClickListener(view1 -> startActivity(new Intent(requireContext(), cn.jiguang.demo.jpush.AdvActivity.class)));
        view.findViewById(R.id.btn_test).setOnClickListener(view1 -> startActivity(new Intent(requireContext(), cn.jiguang.demo.jpush.TestActivity.class)));
        view.findViewById(R.id.btn_open_click).setOnClickListener(view1 -> startActivity(new Intent(requireContext(), cn.jiguang.demo.jpush.OpenClickActivity.class)));
        view.findViewById(R.id.btn_push).setOnClickListener(view1 -> startActivity(new Intent(requireContext(), cn.jiguang.demo.jpush.PushActivity.class)));
    }

}